Optimal. Leaf size=223 \[ -\frac {\sqrt {\frac {\pi }{2}} \cos \left (\frac {a}{b}\right ) S\left (\frac {\sqrt {\frac {2}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}-\frac {\sqrt {\frac {\pi }{6}} \cos \left (\frac {3 a}{b}\right ) S\left (\frac {\sqrt {\frac {6}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}+\frac {\sqrt {\frac {\pi }{2}} \text {FresnelC}\left (\frac {\sqrt {\frac {2}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right ) \sin \left (\frac {a}{b}\right )}{2 \sqrt {b} c^3}+\frac {\sqrt {\frac {\pi }{6}} \text {FresnelC}\left (\frac {\sqrt {\frac {6}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right ) \sin \left (\frac {3 a}{b}\right )}{2 \sqrt {b} c^3} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.22, antiderivative size = 223, normalized size of antiderivative = 1.00, number of steps
used = 13, number of rules used = 7, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.438, Rules used = {4732, 4491,
3387, 3386, 3432, 3385, 3433} \begin {gather*} \frac {\sqrt {\frac {\pi }{2}} \sin \left (\frac {a}{b}\right ) \text {FresnelC}\left (\frac {\sqrt {\frac {2}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}+\frac {\sqrt {\frac {\pi }{6}} \sin \left (\frac {3 a}{b}\right ) \text {FresnelC}\left (\frac {\sqrt {\frac {6}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}-\frac {\sqrt {\frac {\pi }{2}} \cos \left (\frac {a}{b}\right ) S\left (\frac {\sqrt {\frac {2}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}-\frac {\sqrt {\frac {\pi }{6}} \cos \left (\frac {3 a}{b}\right ) S\left (\frac {\sqrt {\frac {6}{\pi }} \sqrt {a+b \text {ArcCos}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 3385
Rule 3386
Rule 3387
Rule 3432
Rule 3433
Rule 4491
Rule 4732
Rubi steps
\begin {align*} \int \frac {x^2}{\sqrt {a+b \cos ^{-1}(c x)}} \, dx &=-\frac {\text {Subst}\left (\int \frac {\cos ^2(x) \sin (x)}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{c^3}\\ &=-\frac {\text {Subst}\left (\int \left (\frac {\sin (x)}{4 \sqrt {a+b x}}+\frac {\sin (3 x)}{4 \sqrt {a+b x}}\right ) \, dx,x,\cos ^{-1}(c x)\right )}{c^3}\\ &=-\frac {\text {Subst}\left (\int \frac {\sin (x)}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{4 c^3}-\frac {\text {Subst}\left (\int \frac {\sin (3 x)}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{4 c^3}\\ &=-\frac {\cos \left (\frac {a}{b}\right ) \text {Subst}\left (\int \frac {\sin \left (\frac {a}{b}+x\right )}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{4 c^3}-\frac {\cos \left (\frac {3 a}{b}\right ) \text {Subst}\left (\int \frac {\sin \left (\frac {3 a}{b}+3 x\right )}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{4 c^3}+\frac {\sin \left (\frac {a}{b}\right ) \text {Subst}\left (\int \frac {\cos \left (\frac {a}{b}+x\right )}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{4 c^3}+\frac {\sin \left (\frac {3 a}{b}\right ) \text {Subst}\left (\int \frac {\cos \left (\frac {3 a}{b}+3 x\right )}{\sqrt {a+b x}} \, dx,x,\cos ^{-1}(c x)\right )}{4 c^3}\\ &=-\frac {\cos \left (\frac {a}{b}\right ) \text {Subst}\left (\int \sin \left (\frac {x^2}{b}\right ) \, dx,x,\sqrt {a+b \cos ^{-1}(c x)}\right )}{2 b c^3}-\frac {\cos \left (\frac {3 a}{b}\right ) \text {Subst}\left (\int \sin \left (\frac {3 x^2}{b}\right ) \, dx,x,\sqrt {a+b \cos ^{-1}(c x)}\right )}{2 b c^3}+\frac {\sin \left (\frac {a}{b}\right ) \text {Subst}\left (\int \cos \left (\frac {x^2}{b}\right ) \, dx,x,\sqrt {a+b \cos ^{-1}(c x)}\right )}{2 b c^3}+\frac {\sin \left (\frac {3 a}{b}\right ) \text {Subst}\left (\int \cos \left (\frac {3 x^2}{b}\right ) \, dx,x,\sqrt {a+b \cos ^{-1}(c x)}\right )}{2 b c^3}\\ &=-\frac {\sqrt {\frac {\pi }{2}} \cos \left (\frac {a}{b}\right ) S\left (\frac {\sqrt {\frac {2}{\pi }} \sqrt {a+b \cos ^{-1}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}-\frac {\sqrt {\frac {\pi }{6}} \cos \left (\frac {3 a}{b}\right ) S\left (\frac {\sqrt {\frac {6}{\pi }} \sqrt {a+b \cos ^{-1}(c x)}}{\sqrt {b}}\right )}{2 \sqrt {b} c^3}+\frac {\sqrt {\frac {\pi }{2}} C\left (\frac {\sqrt {\frac {2}{\pi }} \sqrt {a+b \cos ^{-1}(c x)}}{\sqrt {b}}\right ) \sin \left (\frac {a}{b}\right )}{2 \sqrt {b} c^3}+\frac {\sqrt {\frac {\pi }{6}} C\left (\frac {\sqrt {\frac {6}{\pi }} \sqrt {a+b \cos ^{-1}(c x)}}{\sqrt {b}}\right ) \sin \left (\frac {3 a}{b}\right )}{2 \sqrt {b} c^3}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains complex when optimal does not.
time = 0.29, size = 225, normalized size = 1.01 \begin {gather*} \frac {e^{-\frac {3 i a}{b}} \left (3 e^{\frac {2 i a}{b}} \sqrt {-\frac {i (a+b \text {ArcCos}(c x))}{b}} \text {Gamma}\left (\frac {1}{2},-\frac {i (a+b \text {ArcCos}(c x))}{b}\right )+3 e^{\frac {4 i a}{b}} \sqrt {\frac {i (a+b \text {ArcCos}(c x))}{b}} \text {Gamma}\left (\frac {1}{2},\frac {i (a+b \text {ArcCos}(c x))}{b}\right )+\sqrt {3} \left (\sqrt {-\frac {i (a+b \text {ArcCos}(c x))}{b}} \text {Gamma}\left (\frac {1}{2},-\frac {3 i (a+b \text {ArcCos}(c x))}{b}\right )+e^{\frac {6 i a}{b}} \sqrt {\frac {i (a+b \text {ArcCos}(c x))}{b}} \text {Gamma}\left (\frac {1}{2},\frac {3 i (a+b \text {ArcCos}(c x))}{b}\right )\right )\right )}{24 c^3 \sqrt {a+b \text {ArcCos}(c x)}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.40, size = 198, normalized size = 0.89
method | result | size |
default | \(\frac {\sqrt {\pi }\, \sqrt {2}\, \sqrt {-\frac {1}{b}}\, \left (3 \cos \left (\frac {a}{b}\right ) \mathrm {S}\left (\frac {\sqrt {2}\, \sqrt {a +b \arccos \left (c x \right )}}{\sqrt {\pi }\, \sqrt {-\frac {1}{b}}\, b}\right )+3 \sin \left (\frac {a}{b}\right ) \FresnelC \left (\frac {\sqrt {2}\, \sqrt {a +b \arccos \left (c x \right )}}{\sqrt {\pi }\, \sqrt {-\frac {1}{b}}\, b}\right )-\sqrt {-\frac {1}{b}}\, \sqrt {-\frac {3}{b}}\, \cos \left (\frac {3 a}{b}\right ) \mathrm {S}\left (\frac {3 \sqrt {2}\, \sqrt {a +b \arccos \left (c x \right )}}{\sqrt {\pi }\, \sqrt {-\frac {3}{b}}\, b}\right ) b -\sqrt {-\frac {1}{b}}\, \sqrt {-\frac {3}{b}}\, \sin \left (\frac {3 a}{b}\right ) \FresnelC \left (\frac {3 \sqrt {2}\, \sqrt {a +b \arccos \left (c x \right )}}{\sqrt {\pi }\, \sqrt {-\frac {3}{b}}\, b}\right ) b \right )}{12 c^{3}}\) | \(198\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {x^{2}}{\sqrt {a + b \operatorname {acos}{\left (c x \right )}}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [C] Result contains complex when optimal does not.
time = 0.56, size = 317, normalized size = 1.42 \begin {gather*} \frac {i \, \sqrt {\pi } \operatorname {erf}\left (-\frac {\sqrt {6} \sqrt {b \arccos \left (c x\right ) + a}}{2 \, \sqrt {b}} - \frac {i \, \sqrt {6} \sqrt {b \arccos \left (c x\right ) + a} \sqrt {b}}{2 \, {\left | b \right |}}\right ) e^{\left (\frac {3 i \, a}{b}\right )}}{4 \, {\left (\sqrt {6} \sqrt {b} + \frac {i \, \sqrt {6} b^{\frac {3}{2}}}{{\left | b \right |}}\right )} c^{3}} + \frac {i \, \sqrt {\pi } \operatorname {erf}\left (-\frac {i \, \sqrt {2} \sqrt {b \arccos \left (c x\right ) + a}}{2 \, \sqrt {{\left | b \right |}}} - \frac {\sqrt {2} \sqrt {b \arccos \left (c x\right ) + a} \sqrt {{\left | b \right |}}}{2 \, b}\right ) e^{\left (\frac {i \, a}{b}\right )}}{4 \, c^{3} {\left (\frac {i \, \sqrt {2} b}{\sqrt {{\left | b \right |}}} + \sqrt {2} \sqrt {{\left | b \right |}}\right )}} - \frac {i \, \sqrt {\pi } \operatorname {erf}\left (\frac {i \, \sqrt {2} \sqrt {b \arccos \left (c x\right ) + a}}{2 \, \sqrt {{\left | b \right |}}} - \frac {\sqrt {2} \sqrt {b \arccos \left (c x\right ) + a} \sqrt {{\left | b \right |}}}{2 \, b}\right ) e^{\left (-\frac {i \, a}{b}\right )}}{4 \, c^{3} {\left (-\frac {i \, \sqrt {2} b}{\sqrt {{\left | b \right |}}} + \sqrt {2} \sqrt {{\left | b \right |}}\right )}} - \frac {i \, \sqrt {\pi } \operatorname {erf}\left (-\frac {\sqrt {6} \sqrt {b \arccos \left (c x\right ) + a}}{2 \, \sqrt {b}} + \frac {i \, \sqrt {6} \sqrt {b \arccos \left (c x\right ) + a} \sqrt {b}}{2 \, {\left | b \right |}}\right ) e^{\left (-\frac {3 i \, a}{b}\right )}}{4 \, {\left (\sqrt {6} \sqrt {b} - \frac {i \, \sqrt {6} b^{\frac {3}{2}}}{{\left | b \right |}}\right )} c^{3}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {x^2}{\sqrt {a+b\,\mathrm {acos}\left (c\,x\right )}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________